#include "ThemeItem.h"
#include <string.h>

ThemeItem::ThemeItem() :
		m_pThemeSceneArray(0) {

	if (!m_pThemeSceneArray) {
		m_pThemeSceneArray = CCArray::create();
		m_pThemeSceneArray->retain();
	}

}

ThemeItem::~ThemeItem() {
	m_pThemeSceneArray->release();
}

void ThemeItem::setName(const char * name) {
	memset(this->name, 0, sizeof(this->name));
	memcpy(this->name, name, strlen(name));
}

const char * ThemeItem::getName() {
	return this->name;
}

void ThemeItem::setThumbPath(const char * path) {
	memset(this->thumb_path, 0, sizeof(this->thumb_path));
	memcpy(this->thumb_path, path, strlen(path));
}

const char * ThemeItem::getThumbPath() {
	return this->thumb_path;
}

CCArray * ThemeItem::getThemeScenes() {
	return this->m_pThemeSceneArray;
}

void ThemeItem::addThemeSceneItem(ThemeItemScene * item) {
	m_pThemeSceneArray->addObject(item);
}
